//学生信息相关的接口函数
import request from '@/utils/request'

//根据token更新学生信息
export const updateStudentApi = data => {
    return request({
        url: `/student`,
        method:"put",
        data
    })
}

//获取当前token学生信息
export const getStudentApi = () => {
    return request({
        url: `/student`,
        method:"get"
    })
}

//查找学生信息根据Id
export const getStudentByIdApi = id => {
    return request({
        url: `/student/id/${id}`,
        method:"get"
    })
}


//查找学生信息根据学号
export const getStudentByNoApi = no => {
    return request({
        url: `/student/no/${no}`,
        method:"get",
    })
}

//查找学生根据手机号
export const getStudentByTelephoneApi = telephone => {
    return request({
        url: `/student/telephone/${telephone}`,
        method:"get",
    })
}

//查找学生根据邮箱
export const getStudentByEmailApi = email => {
    return request({
        url: `/student/email/${email}`,
        method:"get",
    })
}


